import java.util.ArrayList;
import java.util.List;

import org.eclipse.swt.graphics.Color;
import org.eclipse.swt.widgets.Display;


public class ColorManager 
{
	private List<Color> listColors;
	
	private Color backgroundColor;
	private Color color1;
	private Color color2;
	private Color color3;
	private Color color4;
	private Color black;
	
	private Display display;
	
	public ColorManager()
	{
		this.listColors = new ArrayList<Color>();
		this.display = Display.getCurrent();
	}
	
	public Color getBlack()
	{
		if(black == null)
		{
			black = new Color(display, 0, 0, 0);
			listColors.add(black);
		}
		
		return black;
	}
	
	public Color getBackgroundColor()
	{
		if(backgroundColor == null)
		{
			backgroundColor = new Color(display, 199, 183, 115);
			listColors.add(backgroundColor);
		}
		
		return backgroundColor;
	}
	
	public Color getColor1()
	{
		if(color1 == null)
		{
			color1 = new Color(display, 227, 219, 154);
			listColors.add(color1);
		}
		
		return color1;
	}
	
	public Color getColor2()
	{
		if(color2 == null)
		{
			color2 = new Color(display, 245, 252, 208);
			listColors.add(color2);
		}
		
		return color2;
	}
	
	public Color getColor3()
	{
		if(color3 == null)
		{
			color3 = new Color(display, 177, 194, 179);
			listColors.add(color3);
		}
		
		return color3;
	}
	
	public Color getColor4()
	{
		if(color4 == null)
		{
			color4 = new Color(display, 119, 134, 145);
			listColors.add(color4);
		}
		
		return color4;
	}
	
	public List<Color> getAllColorInitialized()
	{
		return listColors;
	}
}
